<script setup>
import { onMounted, ref, useTemplateRef } from 'vue';
const myInput = useTemplateRef('my-input')

onMounted(() => {
    //myInput.value.focus()
})
</script>

<template>
    <h1>Vue Cite</h1>

    (ref:console.log('hello,world'))myInput.value.focus:
    <input :ref="() => {console.log('hello,world')}" name="input">

    <br>
    (ref:my-input)myInput.value.focus:
    <input ref="my-input" name="input">
    
</template>

<style scoped>
</style>